ALMaSS  1.0
The Animal, Landscape and Man Simulation System
CfgBase Class Reference

Base class for a configurator entry. More...

#include <configurator.h>

Inheritance diagram for CfgBase:
CfgBool CfgFloat CfgInt CfgStr

Public Member Functions

 CfgBase (const char *a_key, CfgSecureLevel a_level)
 
virtual ~CfgBase (void)
 
const string getkey (void)
 
virtual CfgType gettype (void)
 
CfgSecureLevel getlevel (void)
 

Protected Attributes

string m_key
 
CfgSecureLevel m_level
 
bool m_rangetest
 

Detailed Description

Base class for a configurator entry.

Constructor & Destructor Documentation

◆ CfgBase()

CfgBase::CfgBase ( const char *  a_key,
CfgSecureLevel  a_level 
)
74 {
75  if ( NULL == g_cfg ) {
76  g_cfg = new Configurator;
77  }
78 
79  m_key = a_key;
80  m_level = a_level;
81  m_rangetest = false;
82  g_cfg->Register( this, a_key );
83 }
string m_key
Definition: configurator.h:71
bool m_rangetest
Definition: configurator.h:73
CfgSecureLevel m_level
Definition: configurator.h:72
A class to provide standard parameter entry facilities.
Definition: configurator.h:162
bool Register(CfgBase *a_cfgval, const char *a_key)
Definition: configurator.cpp:182
class Configurator * g_cfg
Definition: configurator.cpp:49

References Configurator::Configurator(), g_cfg, and Configurator::Register().

◆ ~CfgBase()

CfgBase::~CfgBase ( void  )
virtual
88 {
89  ;
90 }

Member Function Documentation

◆ getkey()

const string CfgBase::getkey ( void  )
inline
79 { return m_key; }

◆ getlevel()

CfgSecureLevel CfgBase::getlevel ( void  )
inline
81 { return m_level; }

◆ gettype()

virtual CfgType CfgBase::gettype ( void  )
inlinevirtual

Reimplemented in CfgStr, CfgBool, CfgFloat, and CfgInt.

80 { return CFG_NONE; }
@ CFG_NONE
Definition: configurator.h:52

References CFG_NONE.

Member Data Documentation

◆ m_key

string CfgBase::m_key
protected

◆ m_level

CfgSecureLevel CfgBase::m_level
protected

◆ m_rangetest

bool CfgBase::m_rangetest
protected

The documentation for this class was generated from the following files: